<template>
  <div>{{ count }}</div>
  <button @click="btn(1)">加1</button>
  <button @click="count++">加1第二种方法</button>
  <button @click="count += 100">加1第二种方法</button>
</template>

<script>
import { ref } from "vue";
export default {
  setup() {
    const count = ref(0);
    const btn = (val) => {
      count.value += val;
    };
    return { count, btn };
  },
};
</script>

<style>
</style>
